Optimal. Leaf size=28 \[ \frac {B \sin (c+d x)}{d}-\frac {B \sin ^3(c+d x)}{3 d} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.01, antiderivative size = 28, normalized size of antiderivative = 1.00, number of steps
used = 3, number of rules used = 2, integrand size = 34, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.059, Rules used = {21, 2713}
\begin {gather*} \frac {B \sin (c+d x)}{d}-\frac {B \sin ^3(c+d x)}{3 d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 21
Rule 2713
Rubi steps
\begin {align*} \int \frac {\cos ^3(c+d x) (a B+b B \cos (c+d x))}{a+b \cos (c+d x)} \, dx &=B \int \cos ^3(c+d x) \, dx\\ &=-\frac {B \text {Subst}\left (\int \left (1-x^2\right ) \, dx,x,-\sin (c+d x)\right )}{d}\\ &=\frac {B \sin (c+d x)}{d}-\frac {B \sin ^3(c+d x)}{3 d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.01, size = 28, normalized size = 1.00 \begin {gather*} B \left (\frac {\sin (c+d x)}{d}-\frac {\sin ^3(c+d x)}{3 d}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.16, size = 23, normalized size = 0.82
method | result | size |
derivativedivides | \(\frac {B \left (\cos ^{2}\left (d x +c \right )+2\right ) \sin \left (d x +c \right )}{3 d}\) | \(23\) |
default | \(\frac {B \left (\cos ^{2}\left (d x +c \right )+2\right ) \sin \left (d x +c \right )}{3 d}\) | \(23\) |
risch | \(\frac {3 B \sin \left (d x +c \right )}{4 d}+\frac {B \sin \left (3 d x +3 c \right )}{12 d}\) | \(29\) |
norman | \(\frac {\frac {2 B \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{d}+\frac {10 B \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{3 d}+\frac {10 B \left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{3 d}+\frac {2 B \left (\tan ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}}{\left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )^{4}}\) | \(84\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: ValueError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.37, size = 25, normalized size = 0.89 \begin {gather*} \frac {{\left (B \cos \left (d x + c\right )^{2} + 2 \, B\right )} \sin \left (d x + c\right )}{3 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 56 vs.
\(2 (22) = 44\).
time = 0.46, size = 56, normalized size = 2.00 \begin {gather*} \begin {cases} \frac {2 B \sin ^{3}{\left (c + d x \right )}}{3 d} + \frac {B \sin {\left (c + d x \right )} \cos ^{2}{\left (c + d x \right )}}{d} & \text {for}\: d \neq 0 \\\frac {x \left (B a + B b \cos {\left (c \right )}\right ) \cos ^{3}{\left (c \right )}}{a + b \cos {\left (c \right )}} & \text {otherwise} \end {cases} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.43, size = 25, normalized size = 0.89 \begin {gather*} -\frac {B \sin \left (d x + c\right )^{3} - 3 \, B \sin \left (d x + c\right )}{3 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.48, size = 24, normalized size = 0.86 \begin {gather*} \frac {B\,\left (9\,\sin \left (c+d\,x\right )+\sin \left (3\,c+3\,d\,x\right )\right )}{12\,d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________